package com.neuedu.opp02ex;

public class SalariedEmployee extends ColaEmployee {
    /**
     * 月工资
     */
    private double monthlySalary;

    public SalariedEmployee() {
    }

    public SalariedEmployee(String name, int birthMonth, double monthlySalary) {
        super(name, birthMonth);
        this.monthlySalary = monthlySalary;
    }

    public double getMonthlySalary() {
        return monthlySalary;
    }

    public void setMonthlySalary(double monthlySalary) {
        this.monthlySalary = monthlySalary;
    }

    @Override
    public double getSalary(int month) {
        super.getSalary(month);
        return salary + monthlySalary;
    }
}
